package com.quick.tim.mobileserviceprovider.entity;
// Generated Oct 24, 2013 2:28:19 PM by Hibernate Tools 3.2.1.GA


import javax.persistence.AttributeOverride;
import javax.persistence.AttributeOverrides;
import javax.persistence.Column;
import javax.persistence.EmbeddedId;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

/**
 * ForumEventComments generated by hbm2java
 */
@Entity
@Table(name="forum_event_comments", schema="public"
)
public class ForumEventComments  implements java.io.Serializable {


     private ForumEventCommentsId id;
     private ForumEventDetails forumEventDetails;
     private String name;
     private String commentBody;

    public ForumEventComments() {
    }

	
    public ForumEventComments(ForumEventCommentsId id, ForumEventDetails forumEventDetails) {
        this.id = id;
        this.forumEventDetails = forumEventDetails;
    }
    public ForumEventComments(ForumEventCommentsId id, ForumEventDetails forumEventDetails, String name, String commentBody) {
       this.id = id;
       this.forumEventDetails = forumEventDetails;
       this.name = name;
       this.commentBody = commentBody;
    }
   
     @EmbeddedId
    
    @AttributeOverrides( {
        @AttributeOverride(name="eventDetailId", column=@Column(name="event_detail_id", nullable=false) ), 
        @AttributeOverride(name="username", column=@Column(name="username", nullable=false, length=250) ), 
        @AttributeOverride(name="commentTime", column=@Column(name="comment_time", nullable=false, length=35) ) } )
    public ForumEventCommentsId getId() {
        return this.id;
    }
    
    public void setId(ForumEventCommentsId id) {
        this.id = id;
    }
@ManyToOne(fetch=FetchType.LAZY)
    @JoinColumn(name="event_detail_id", nullable=false, insertable=false, updatable=false)
    public ForumEventDetails getForumEventDetails() {
        return this.forumEventDetails;
    }
    
    public void setForumEventDetails(ForumEventDetails forumEventDetails) {
        this.forumEventDetails = forumEventDetails;
    }
    
    @Column(name="name", length=200)
    public String getName() {
        return this.name;
    }
    
    public void setName(String name) {
        this.name = name;
    }
    
    @Column(name="comment_body", length=1000)
    public String getCommentBody() {
        return this.commentBody;
    }
    
    public void setCommentBody(String commentBody) {
        this.commentBody = commentBody;
    }




}


